package day6;

import javax.xml.crypto.dsig.SignatureMethod;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @author oldliu
 * @since 1.0
 */
public class SimpleDAteTest {
    public static void main(String[] args) {
        SimpleDateFormat df=new SimpleDateFormat("yyyy-MM-dd");
        String str="2023-01-03";
        Date d = null;
        try {
            d = df.parse(str);
            System.out.println(d);
        } catch (ParseException e) {
            e.printStackTrace();
        }

    }
}
